package top.huhuiyu.springboot3.controller.api;

import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import top.huhuiyu.springboot3.base.R;
import top.huhuiyu.springboot3.entity.api.TbDataHistory;
import top.huhuiyu.springboot3.service.api.HistoryService;

@RestController
@RequiredArgsConstructor
@RequestMapping("/autodata")
public class AutoDataController {
    private final HistoryService historyService;

    @RequestMapping("/history")
    public R<TbDataHistory> randHistory() {
        return historyService.randHistory();
    }

}
